Remove gtktypeutils altogether
authorMatthias Clasen <mclasen@redhat.com>
Tue, 4 Jan 2011 19:51:19 +0000 (14:51 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Tue, 4 Jan 2011 19:51:19 +0000 (14:51 -0500)
Based on patches by Javier Jardón.

https://bugzilla.gnome.org/show_bug.cgi?id=629955

51 files changed:
gtk/Makefile.am
gtk/gtk.h
gtk/gtkaboutdialog.c
gtk/gtkactiongroup.h
gtk/gtkassistant.c
gtk/gtkbindings.c
gtk/gtkbutton.c
gtk/gtkcellrendereraccel.c
gtk/gtkcombobox.c
gtk/gtkcontainer.c
gtk/gtkentry.c
gtk/gtkfilechooserbutton.c
gtk/gtkframe.c
gtk/gtkhandlebox.c
gtk/gtkiconfactory.c
gtk/gtkiconview.c
gtk/gtkimage.c
gtk/gtkinfobar.c
gtk/gtklabel.c
gtk/gtkmain.h
gtk/gtkmenu.c
gtk/gtkmenubar.c
gtk/gtkmenuitem.c
gtk/gtkmenushell.c
gtk/gtkmessagedialog.c
gtk/gtknotebook.c
gtk/gtkpaned.c
gtk/gtkprintoperation.c
gtk/gtkprintsettings.c
gtk/gtkprintunixdialog.c
gtk/gtkrange.c
gtk/gtkscalebutton.c
gtk/gtkscrolledwindow.c
gtk/gtkspinbutton.c
gtk/gtkstatusbar.c
gtk/gtkstatusicon.c
gtk/gtkstock.h
gtk/gtktexttag.c
gtk/gtktextview.c
gtk/gtktoolbar.c
gtk/gtktoolitemgroup.c
gtk/gtktoolpalette.c
gtk/gtktrayicon-x11.c
gtk/gtktreeview.c
gtk/gtktreeviewcolumn.c
gtk/gtktypeutils.c [deleted file]
gtk/gtktypeutils.h [deleted file]
gtk/gtkwidget.c
gtk/gtkwindow.c
po-properties/POTFILES.in
po/POTFILES.in

index 6dd2e01b20b1592a59180d3dc94783cfb99a7ed3..79aeb455c2a1172a8e9111d60e3ee1eb04bd6afc 100644 (file)
@@ -333,7 +333,6 @@ gtk_public_h_sources =              \
        gtktreestore.h          \
        gtktreeview.h           \
        gtktreeviewcolumn.h     \
-       gtktypeutils.h          \
        gtkuimanager.h          \
        gtkvbbox.h              \
        gtkvbox.h               \
@@ -662,7 +661,6 @@ gtk_base_c_sources =                \
        gtktreeview.c           \
        gtktreeviewcolumn.c     \
        gtktypebuiltins.c       \
-       gtktypeutils.c          \
        gtkuimanager.c          \
        gtkvbbox.c              \
        gtkvbox.c               \
index 0d85793a3cf4e1494098cbe1adf0e4cf13344928..29b41f29beb3917c14be79895f8d695bc24b3b21 100644 (file)
--- a/gtk/gtk.h
+++ b/gtk/gtk.h
 #include <gtk/gtktreestore.h>
 #include <gtk/gtktreeview.h>
 #include <gtk/gtktreeviewcolumn.h>
-#include <gtk/gtktypeutils.h>
+#include <gtk/gtktypebuiltins.h>
 #include <gtk/gtkuimanager.h>
 #include <gtk/gtkvbbox.h>
 #include <gtk/gtkvbox.h>
index ea4d9304acdd678851b0c6c1ff24317b2ac94f2d..d63054f13ef161c5f734601a861e9d0598c81993 100644 (file)
@@ -54,6 +54,7 @@
 #include "gtkmain.h"
 #include "gtkmessagedialog.h"
 #include "gtktogglebutton.h"
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
 
index c77987c12730bf7a0c7425518f513eba0c9090d9..33fa000dfac341d9ed5573b6d3137cfca280dfd8 100644 (file)
@@ -36,7 +36,7 @@
 #define __GTK_ACTION_GROUP_H__
 
 #include <gtk/gtkaction.h>
-#include <gtk/gtktypeutils.h> /* for GtkTranslateFunc */
+#include <gtk/gtkstock.h>
 
 G_BEGIN_DECLS
 
index e3a5af7f2f99bafa56db5c2c024ebc7d11b1bf67..fa740bd18a3cbd083b9542e820a1979b63e04c5d 100644 (file)
@@ -71,7 +71,7 @@
 #include "gtksizegroup.h"
 #include "gtksizerequest.h"
 #include "gtkstock.h"
-
+#include "gtktypebuiltins.h"
 #include "gtkintl.h"
 #include "gtkprivate.h"
 #include "gtkbuildable.h"
index e8b0b632e448e36893ff4c546746b1bf0d2ddad4..733c9b10603a82e731eb203b8ffd5670efa7bde3 100644 (file)
@@ -11,7 +11,7 @@
  *
  * This library is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.         See the GNU
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
  *
  * You should have received a copy of the GNU Lesser General Public
 #include <stdarg.h>
 
 #include "gtkbindings.h"
-#include "gtktypeutils.h"
 #include "gtkkeyhash.h"
 #include "gtkwidget.h"
 #include "gtkrc.h"
-
+#include "gtkintl.h"
 
 /* --- defines --- */
-#define        BINDING_MOD_MASK()      (gtk_accelerator_get_default_mod_mask () | GDK_RELEASE_MASK)
+#define BINDING_MOD_MASK() (gtk_accelerator_get_default_mod_mask () | GDK_RELEASE_MASK)
+
+
+#define GTK_TYPE_IDENTIFIER (gtk_identifier_get_type ())
+GType gtk_identifier_get_type (void) G_GNUC_CONST;
 
 
 /* --- structures --- */
@@ -52,14 +55,28 @@ typedef struct {
 
 
 /* --- variables --- */
-static GHashTable      *binding_entry_hash_table = NULL;
+static GHashTable       *binding_entry_hash_table = NULL;
 static GSList           *binding_key_hashes = NULL;
-static GSList          *binding_set_list = NULL;
-static const gchar      key_class_binding_set[] = "gtk-class-binding-set";
-static GQuark           key_id_class_binding_set = 0;
+static GSList           *binding_set_list = NULL;
+static const gchar       key_class_binding_set[] = "gtk-class-binding-set";
+static GQuark            key_id_class_binding_set = 0;
 
 
 /* --- functions --- */
+GType
+gtk_identifier_get_type (void)
+{
+  static GType our_type = 0;
+
+  if (our_type == 0)
+    {
+      GTypeInfo tinfo = { 0, };
+      our_type = g_type_register_static (G_TYPE_STRING, I_("GtkIdentifier"), &tinfo, 0);
+    }
+
+  return our_type;
+}
+
 static void
 pattern_spec_free (PatternSpec *pspec)
 {
@@ -70,7 +87,7 @@ pattern_spec_free (PatternSpec *pspec)
 
 static GtkBindingSignal*
 binding_signal_new (const gchar *signal_name,
-                   guint        n_args)
+                    guint        n_args)
 {
   GtkBindingSignal *signal;
 
@@ -91,7 +108,7 @@ binding_signal_free (GtkBindingSignal *sig)
   for (i = 0; i < sig->n_args; i++)
     {
       if (G_TYPE_FUNDAMENTAL (sig->args[i].arg_type) == G_TYPE_STRING)
-       g_free (sig->args[i].d.string_data);
+        g_free (sig->args[i].d.string_data);
     }
   g_slice_free1 (sizeof (GtkBindingSignal) + sig->n_args * sizeof (GtkBindingArg), sig);
 }
@@ -110,7 +127,7 @@ binding_entry_hash (gconstpointer  key)
 
 static gint
 binding_entries_compare (gconstpointer  a,
-                        gconstpointer  b)
+                         gconstpointer  b)
 {
   register const GtkBindingEntry *ea = a;
   register const GtkBindingEntry *eb = b;
@@ -120,7 +137,7 @@ binding_entries_compare (gconstpointer  a,
 
 static void
 binding_key_hash_insert_entry (GtkKeyHash      *key_hash,
-                              GtkBindingEntry *entry)
+                               GtkBindingEntry *entry)
 {
   guint keyval = entry->keyval;
   
@@ -130,9 +147,9 @@ binding_key_hash_insert_entry (GtkKeyHash      *key_hash,
   if (entry->modifiers & GDK_SHIFT_MASK)
     {
       if (keyval == GDK_KEY_Tab)
-       keyval = GDK_KEY_ISO_Left_Tab;
+        keyval = GDK_KEY_ISO_Left_Tab;
       else
-       keyval = gdk_keyval_to_upper (keyval);
+        keyval = gdk_keyval_to_upper (keyval);
     }
   
   _gtk_key_hash_add_entry (key_hash, keyval, entry->modifiers & ~GDK_RELEASE_MASK, entry);
@@ -149,8 +166,8 @@ binding_key_hash_destroy (gpointer data)
 
 static void
 insert_entries_into_key_hash (gpointer key,
-                             gpointer value,
-                             gpointer data)
+                              gpointer value,
+                              gpointer data)
 {
   GtkKeyHash *key_hash = data;
   GtkBindingEntry *entry = value;
@@ -176,9 +193,9 @@ binding_key_hash_for_keymap (GdkKeymap *keymap)
       g_object_set_qdata_full (G_OBJECT (keymap), key_hash_quark, key_hash, binding_key_hash_destroy);
 
       if (binding_entry_hash_table)
-       g_hash_table_foreach (binding_entry_hash_table,
-                             insert_entries_into_key_hash,
-                             key_hash);
+        g_hash_table_foreach (binding_entry_hash_table,
+                              insert_entries_into_key_hash,
+                              key_hash);
 
       binding_key_hashes = g_slist_prepend (binding_key_hashes, key_hash);
     }
@@ -189,8 +206,8 @@ binding_key_hash_for_keymap (GdkKeymap *keymap)
 
 static GtkBindingEntry*
 binding_entry_new (GtkBindingSet  *binding_set,
-                  guint           keyval,
-                  GdkModifierType modifiers)
+                   guint           keyval,
+                   GdkModifierType modifiers)
 {
   GSList *tmp_list;
   GtkBindingEntry *entry;
@@ -230,9 +247,9 @@ binding_entry_free (GtkBindingEntry *entry)
   GtkBindingSignal *sig;
 
   g_assert (entry->set_next == NULL &&
-           entry->hash_next == NULL &&
-           entry->in_emission == FALSE &&
-           entry->destroyed == TRUE);
+            entry->hash_next == NULL &&
+            entry->in_emission == FALSE &&
+            entry->destroyed == TRUE);
 
   entry->destroyed = FALSE;
   
@@ -264,13 +281,13 @@ binding_entry_destroy (GtkBindingEntry *entry)
   while (tmp)
     {
       if (tmp == entry)
-       {
-         if (last)
-           last->set_next = entry->set_next;
-         else
-           entry->binding_set->entries = entry->set_next;
-         break;
-       }
+        {
+          if (last)
+            last->set_next = entry->set_next;
+          else
+            entry->binding_set->entries = entry->set_next;
+          break;
+        }
       last = tmp;
       tmp = last->set_next;
     }
@@ -283,13 +300,13 @@ binding_entry_destroy (GtkBindingEntry *entry)
   while (tmp)
     {
       if (tmp == entry)
-       {
-         if (last)
-           last->hash_next = entry->hash_next;
-         else
-           begin = entry->hash_next;
-         break;
-       }
+        {
+          if (last)
+            last->hash_next = entry->hash_next;
+          else
+            begin = entry->hash_next;
+          break;
+        }
       last = tmp;
       tmp = last->hash_next;
     }
@@ -317,8 +334,8 @@ binding_entry_destroy (GtkBindingEntry *entry)
 
 static GtkBindingEntry*
 binding_ht_lookup_entry (GtkBindingSet  *set,
-                        guint           keyval,
-                        GdkModifierType modifiers)
+                         guint           keyval,
+                         GdkModifierType modifiers)
 {
   GtkBindingEntry lookup_entry = { 0 };
   GtkBindingEntry *entry;
@@ -339,9 +356,9 @@ binding_ht_lookup_entry (GtkBindingSet  *set,
 
 static gboolean
 binding_compose_params (GObject         *object,
-                       GtkBindingArg   *args,
-                       GSignalQuery    *query,
-                       GValue         **params_p)
+                        GtkBindingArg   *args,
+                        GSignalQuery    *query,
+                        GValue         **params_p)
 {
   GValue *params;
   const GType *types;
@@ -366,85 +383,85 @@ binding_compose_params (GObject         *object,
       g_value_init (params, *types);
 
       switch (G_TYPE_FUNDAMENTAL (args->arg_type))
-       {
-       case G_TYPE_DOUBLE:
-         g_value_init (&tmp_value, G_TYPE_DOUBLE);
-         g_value_set_double (&tmp_value, args->d.double_data);
-         break;
-       case G_TYPE_LONG:
-         g_value_init (&tmp_value, G_TYPE_LONG);
-         g_value_set_long (&tmp_value, args->d.long_data);
-         break;
-       case G_TYPE_STRING:
-         /* gtk_rc_parse_flags/enum() has fancier parsing for this; we can't call
-          * that since we don't have a GParamSpec, so just do something simple
-          */
-         if (G_TYPE_FUNDAMENTAL (*types) == G_TYPE_ENUM)
-           {
-             GEnumClass *class = G_ENUM_CLASS (g_type_class_ref (*types));
-             
-             valid = FALSE;
-             
-             if (args->arg_type == GTK_TYPE_IDENTIFIER)
-               {
-                 GEnumValue *enum_value = NULL;
-                 enum_value = g_enum_get_value_by_name (class, args->d.string_data);
-                 if (!enum_value)
-                   enum_value = g_enum_get_value_by_nick (class, args->d.string_data);
-                 if (enum_value)
-                   {
-                     g_value_init (&tmp_value, *types);
-                     g_value_set_enum (&tmp_value, enum_value->value);
-                     valid = TRUE;
-                   }
-               }
-
-             g_type_class_unref (class);
-           }
-         /* This is just a hack for compatibility with GTK+-1.2 where a string
-          * could be used for a single flag value / without the support for multiple
-          * values in gtk_rc_parse_flags(), this isn't very useful.
-          */
-         else if (G_TYPE_FUNDAMENTAL (*types) == G_TYPE_FLAGS)
-           {
-             GFlagsClass *class = G_FLAGS_CLASS (g_type_class_ref (*types));
-             
-             valid = FALSE;
-             
-             if (args->arg_type == GTK_TYPE_IDENTIFIER)
-               {
-                 GFlagsValue *flags_value = NULL;
-                 flags_value = g_flags_get_value_by_name (class, args->d.string_data);
-                 if (!flags_value)
-                   flags_value = g_flags_get_value_by_nick (class, args->d.string_data);
-                 if (flags_value)
-                   {
-                     g_value_init (&tmp_value, *types);
-                     g_value_set_flags (&tmp_value, flags_value->value);
-                     valid = TRUE;
-                   }
-               }
-
-             g_type_class_unref (class);
-           }
-         else
-           {
-             g_value_init (&tmp_value, G_TYPE_STRING);
-             g_value_set_static_string (&tmp_value, args->d.string_data);
-           }
-         break;
-       default:
-         valid = FALSE;
-         break;
-       }
+        {
+        case G_TYPE_DOUBLE:
+          g_value_init (&tmp_value, G_TYPE_DOUBLE);
+          g_value_set_double (&tmp_value, args->d.double_data);
+          break;
+        case G_TYPE_LONG:
+          g_value_init (&tmp_value, G_TYPE_LONG);
+          g_value_set_long (&tmp_value, args->d.long_data);
+          break;
+        case G_TYPE_STRING:
+          /* gtk_rc_parse_flags/enum() has fancier parsing for this; we can't call
+           * that since we don't have a GParamSpec, so just do something simple
+           */
+          if (G_TYPE_FUNDAMENTAL (*types) == G_TYPE_ENUM)
+            {
+              GEnumClass *class = G_ENUM_CLASS (g_type_class_ref (*types));
+
+              valid = FALSE;
+
+              if (args->arg_type == GTK_TYPE_IDENTIFIER)
+                {
+                  GEnumValue *enum_value = NULL;
+                  enum_value = g_enum_get_value_by_name (class, args->d.string_data);
+                  if (!enum_value)
+                    enum_value = g_enum_get_value_by_nick (class, args->d.string_data);
+                  if (enum_value)
+                    {
+                      g_value_init (&tmp_value, *types);
+                      g_value_set_enum (&tmp_value, enum_value->value);
+                      valid = TRUE;
+                    }
+                }
+
+              g_type_class_unref (class);
+            }
+          /* This is just a hack for compatibility with GTK+-1.2 where a string
+           * could be used for a single flag value / without the support for multiple
+           * values in gtk_rc_parse_flags(), this isn't very useful.
+           */
+          else if (G_TYPE_FUNDAMENTAL (*types) == G_TYPE_FLAGS)
+            {
+              GFlagsClass *class = G_FLAGS_CLASS (g_type_class_ref (*types));
+
+              valid = FALSE;
+
+              if (args->arg_type == GTK_TYPE_IDENTIFIER)
+                {
+                  GFlagsValue *flags_value = NULL;
+                  flags_value = g_flags_get_value_by_name (class, args->d.string_data);
+                  if (!flags_value)
+                    flags_value = g_flags_get_value_by_nick (class, args->d.string_data);
+                  if (flags_value)
+                    {
+                      g_value_init (&tmp_value, *types);
+                      g_value_set_flags (&tmp_value, flags_value->value);
+                      valid = TRUE;
+                    }
+                }
+
+              g_type_class_unref (class);
+            }
+          else
+            {
+              g_value_init (&tmp_value, G_TYPE_STRING);
+              g_value_set_static_string (&tmp_value, args->d.string_data);
+            }
+          break;
+        default:
+          valid = FALSE;
+          break;
+        }
 
       if (valid)
-       {
-         if (!g_value_transform (&tmp_value, params))
-           valid = FALSE;
+        {
+          if (!g_value_transform (&tmp_value, params))
+            valid = FALSE;
 
-         g_value_unset (&tmp_value);
-       }
+          g_value_unset (&tmp_value);
+        }
       
       types++;
       params++;
@@ -456,7 +473,7 @@ binding_compose_params (GObject         *object,
       guint j;
 
       for (j = 0; j < i; j++)
-       g_value_unset (&(*params_p)[j]);
+        g_value_unset (&(*params_p)[j]);
       
       g_free (*params_p);
       *params_p = NULL;
@@ -467,7 +484,7 @@ binding_compose_params (GObject         *object,
 
 static gboolean
 gtk_binding_entry_activate (GtkBindingEntry *entry,
-                           GObject         *object)
+                            GObject         *object)
 {
   GtkBindingSignal *sig;
   gboolean old_emission;
@@ -489,65 +506,65 @@ gtk_binding_entry_activate (GtkBindingEntry *entry,
       
       signal_id = g_signal_lookup (sig->signal_name, G_OBJECT_TYPE (object));
       if (!signal_id)
-       {
-         accelerator = gtk_accelerator_name (entry->keyval, entry->modifiers);
-         g_warning ("gtk_binding_entry_activate(): binding \"%s::%s\": "
-                    "could not find signal \"%s\" in the `%s' class ancestry",
-                    entry->binding_set->set_name,
-                    accelerator,
-                    sig->signal_name,
-                    g_type_name (G_OBJECT_TYPE (object)));
-         g_free (accelerator);
-         continue;
-       }
-      
+        {
+          accelerator = gtk_accelerator_name (entry->keyval, entry->modifiers);
+          g_warning ("gtk_binding_entry_activate(): binding \"%s::%s\": "
+                     "could not find signal \"%s\" in the `%s' class ancestry",
+                     entry->binding_set->set_name,
+                     accelerator,
+                     sig->signal_name,
+                     g_type_name (G_OBJECT_TYPE (object)));
+          g_free (accelerator);
+          continue;
+        }
+
       g_signal_query (signal_id, &query);
       if (query.n_params != sig->n_args ||
-         (query.return_type != G_TYPE_NONE && query.return_type != G_TYPE_BOOLEAN) || 
-         !binding_compose_params (object, sig->args, &query, &params))
-       {
-         accelerator = gtk_accelerator_name (entry->keyval, entry->modifiers);
-         g_warning ("gtk_binding_entry_activate(): binding \"%s::%s\": "
-                    "signature mismatch for signal \"%s\" in the `%s' class ancestry",
-                    entry->binding_set->set_name,
-                    accelerator,
-                    sig->signal_name,
-                    g_type_name (G_OBJECT_TYPE (object)));
-       }
+          (query.return_type != G_TYPE_NONE && query.return_type != G_TYPE_BOOLEAN) ||
+          !binding_compose_params (object, sig->args, &query, &params))
+        {
+          accelerator = gtk_accelerator_name (entry->keyval, entry->modifiers);
+          g_warning ("gtk_binding_entry_activate(): binding \"%s::%s\": "
+                     "signature mismatch for signal \"%s\" in the `%s' class ancestry",
+                     entry->binding_set->set_name,
+                     accelerator,
+                     sig->signal_name,
+                     g_type_name (G_OBJECT_TYPE (object)));
+        }
       else if (!(query.signal_flags & G_SIGNAL_ACTION))
-       {
-         accelerator = gtk_accelerator_name (entry->keyval, entry->modifiers);
-         g_warning ("gtk_binding_entry_activate(): binding \"%s::%s\": "
-                    "signal \"%s\" in the `%s' class ancestry cannot be used for action emissions",
-                    entry->binding_set->set_name,
-                    accelerator,
-                    sig->signal_name,
-                    g_type_name (G_OBJECT_TYPE (object)));
-       }
+        {
+          accelerator = gtk_accelerator_name (entry->keyval, entry->modifiers);
+          g_warning ("gtk_binding_entry_activate(): binding \"%s::%s\": "
+                     "signal \"%s\" in the `%s' class ancestry cannot be used for action emissions",
+                     entry->binding_set->set_name,
+                     accelerator,
+                     sig->signal_name,
+                     g_type_name (G_OBJECT_TYPE (object)));
+        }
       g_free (accelerator);
       if (accelerator)
-       continue;
+        continue;
 
       if (query.return_type == G_TYPE_BOOLEAN)
-       g_value_init (&return_val, G_TYPE_BOOLEAN);
+        g_value_init (&return_val, G_TYPE_BOOLEAN);
       
       g_signal_emitv (params, signal_id, 0, &return_val);
 
       if (query.return_type == G_TYPE_BOOLEAN)
-       {
-         if (g_value_get_boolean (&return_val))
-           handled = TRUE;
-         g_value_unset (&return_val);
-       }
+        {
+          if (g_value_get_boolean (&return_val))
+            handled = TRUE;
+          g_value_unset (&return_val);
+        }
       else
-       handled = TRUE;
+        handled = TRUE;
       
       for (i = 0; i < query.n_params + 1; i++)
-       g_value_unset (&params[i]);
+        g_value_unset (&params[i]);
       g_free (params);
       
       if (entry->destroyed)
-       break;
+        break;
     }
   
   g_object_unref (object);
@@ -617,9 +634,9 @@ gtk_binding_set_by_class (gpointer object_class)
 
   binding_set = gtk_binding_set_new (g_type_name (G_OBJECT_CLASS_TYPE (class)));
   gtk_binding_set_add_path (binding_set,
-                           GTK_PATH_CLASS,
-                           g_type_name (G_OBJECT_CLASS_TYPE (class)),
-                           GTK_PATH_PRIO_GTK);
+                            GTK_PATH_CLASS,
+                            g_type_name (G_OBJECT_CLASS_TYPE (class)),
+                            GTK_PATH_PRIO_GTK);
   g_dataset_id_set_data (class, key_id_class_binding_set, binding_set);
 
   return binding_set;
@@ -648,7 +665,7 @@ gtk_binding_set_find (const gchar *set_name)
       
       binding_set = slist->data;
       if (g_str_equal (binding_set->set_name, (gpointer) set_name))
-       return binding_set;
+        return binding_set;
     }
   return NULL;
 }
@@ -666,10 +683,10 @@ gtk_binding_set_find (const gchar *set_name)
  * Return value: %TRUE if a binding was found and activated
  */
 gboolean
-gtk_binding_set_activate (GtkBindingSet         *binding_set,
-                         guint           keyval,
-                         GdkModifierType modifiers,
-                         GObject        *object)
+gtk_binding_set_activate (GtkBindingSet  *binding_set,
+                          guint           keyval,
+                          GdkModifierType modifiers,
+                          GObject        *object)
 {
   GtkBindingEntry *entry;
   
@@ -745,9 +762,9 @@ gtk_binding_entry_skip (GtkBindingSet  *binding_set,
  * gtk_binding_entry_add_signal() on @binding_set.
  */
 void
-gtk_binding_entry_remove (GtkBindingSet         *binding_set,
-                         guint           keyval,
-                         GdkModifierType modifiers)
+gtk_binding_entry_remove (GtkBindingSet  *binding_set,
+                          guint           keyval,
+                          GdkModifierType modifiers)
 {
   GtkBindingEntry *entry;
   
@@ -775,10 +792,10 @@ gtk_binding_entry_remove (GtkBindingSet    *binding_set,
  */
 void
 gtk_binding_entry_add_signall (GtkBindingSet  *binding_set,
-                               guint          keyval,
+                               guint           keyval,
                                GdkModifierType modifiers,
                                const gchar    *signal_name,
-                               GSList        *binding_args)
+                               GSList         *binding_args)
 {
   _gtk_binding_entry_add_signall (binding_set,
                                   keyval, modifiers,
@@ -787,10 +804,10 @@ gtk_binding_entry_add_signall (GtkBindingSet  *binding_set,
 
 void
 _gtk_binding_entry_add_signall (GtkBindingSet  *binding_set,
-                                guint         keyval,
+                                guint          keyval,
                                 GdkModifierType modifiers,
                                 const gchar    *signal_name,
-                                GSList       *binding_args)
+                                GSList        *binding_args)
 {
   GtkBindingEntry *entry;
   GtkBindingSignal *signal, **signal_p;
@@ -813,40 +830,40 @@ _gtk_binding_entry_add_signall (GtkBindingSet  *binding_set,
       
       tmp_arg = slist->data;
       if (!tmp_arg)
-       {
-         g_warning ("gtk_binding_entry_add_signall(): arg[%u] is `NULL'", n);
-         binding_signal_free (signal);
-         return;
-       }
+        {
+          g_warning ("gtk_binding_entry_add_signall(): arg[%u] is `NULL'", n);
+          binding_signal_free (signal);
+          return;
+        }
       switch (G_TYPE_FUNDAMENTAL (tmp_arg->arg_type))
-       {
-       case  G_TYPE_LONG:
-         arg->arg_type = G_TYPE_LONG;
-         arg->d.long_data = tmp_arg->d.long_data;
-         break;
-       case  G_TYPE_DOUBLE:
-         arg->arg_type = G_TYPE_DOUBLE;
-         arg->d.double_data = tmp_arg->d.double_data;
-         break;
-       case  G_TYPE_STRING:
+        {
+        case  G_TYPE_LONG:
+          arg->arg_type = G_TYPE_LONG;
+          arg->d.long_data = tmp_arg->d.long_data;
+          break;
+        case  G_TYPE_DOUBLE:
+          arg->arg_type = G_TYPE_DOUBLE;
+          arg->d.double_data = tmp_arg->d.double_data;
+          break;
+        case  G_TYPE_STRING:
           if (tmp_arg->arg_type != GTK_TYPE_IDENTIFIER)
-           arg->arg_type = G_TYPE_STRING;
-         else
-           arg->arg_type = GTK_TYPE_IDENTIFIER;
-         arg->d.string_data = g_strdup (tmp_arg->d.string_data);
-         if (!arg->d.string_data)
-           {
-             g_warning ("gtk_binding_entry_add_signall(): value of `string' arg[%u] is `NULL'", n);
-             binding_signal_free (signal);
-             return;
-           }
-         break;
-       default:
-         g_warning ("gtk_binding_entry_add_signall(): unsupported type `%s' for arg[%u]",
-                    g_type_name (arg->arg_type), n);
-         binding_signal_free (signal);
-         return;
-       }
+            arg->arg_type = G_TYPE_STRING;
+          else
+            arg->arg_type = GTK_TYPE_IDENTIFIER;
+          arg->d.string_data = g_strdup (tmp_arg->d.string_data);
+          if (!arg->d.string_data)
+            {
+              g_warning ("gtk_binding_entry_add_signall(): value of `string' arg[%u] is `NULL'", n);
+              binding_signal_free (signal);
+              return;
+            }
+          break;
+        default:
+          g_warning ("gtk_binding_entry_add_signall(): unsupported type `%s' for arg[%u]",
+                     g_type_name (arg->arg_type), n);
+          binding_signal_free (signal);
+          return;
+        }
       arg++;
       n++;
     }
@@ -879,11 +896,11 @@ _gtk_binding_entry_add_signall (GtkBindingSet  *binding_set,
  */
 void
 gtk_binding_entry_add_signal (GtkBindingSet  *binding_set,
-                             guint           keyval,
-                             GdkModifierType modifiers,
-                             const gchar    *signal_name,
-                             guint           n_args,
-                             ...)
+                              guint           keyval,
+                              GdkModifierType modifiers,
+                              const gchar    *signal_name,
+                              guint           n_args,
+                              ...)
 {
   GSList *slist, *free_slist;
   va_list args;
@@ -903,45 +920,45 @@ gtk_binding_entry_add_signal (GtkBindingSet  *binding_set,
 
       arg->arg_type = va_arg (args, GType);
       switch (G_TYPE_FUNDAMENTAL (arg->arg_type))
-       {
-       case G_TYPE_CHAR:
-       case G_TYPE_UCHAR:
-       case G_TYPE_INT:
-       case G_TYPE_UINT:
-       case G_TYPE_BOOLEAN:
-       case G_TYPE_ENUM:
-       case G_TYPE_FLAGS:
-         arg->arg_type = G_TYPE_LONG;
-         arg->d.long_data = va_arg (args, gint);
-         break;
-       case G_TYPE_LONG:
-       case G_TYPE_ULONG:
-         arg->arg_type = G_TYPE_LONG;
-         arg->d.long_data = va_arg (args, glong);
-         break;
-       case G_TYPE_FLOAT:
-       case G_TYPE_DOUBLE:
-         arg->arg_type = G_TYPE_DOUBLE;
-         arg->d.double_data = va_arg (args, gdouble);
-         break;
-       case G_TYPE_STRING:
-         if (arg->arg_type != GTK_TYPE_IDENTIFIER)
-           arg->arg_type = G_TYPE_STRING;
-         arg->d.string_data = va_arg (args, gchar*);
-         if (!arg->d.string_data)
-           {
-             g_warning ("gtk_binding_entry_add_signal(): type `%s' arg[%u] is `NULL'",
-                        g_type_name (arg->arg_type),
-                        i);
-             i += n_args + 1;
-           }
-         break;
-       default:
-         g_warning ("gtk_binding_entry_add_signal(): unsupported type `%s' for arg[%u]",
-                    g_type_name (arg->arg_type), i);
-         i += n_args + 1;
-         break;
-       }
+        {
+        case G_TYPE_CHAR:
+        case G_TYPE_UCHAR:
+        case G_TYPE_INT:
+        case G_TYPE_UINT:
+        case G_TYPE_BOOLEAN:
+        case G_TYPE_ENUM:
+        case G_TYPE_FLAGS:
+          arg->arg_type = G_TYPE_LONG;
+          arg->d.long_data = va_arg (args, gint);
+          break;
+        case G_TYPE_LONG:
+        case G_TYPE_ULONG:
+          arg->arg_type = G_TYPE_LONG;
+          arg->d.long_data = va_arg (args, glong);
+          break;
+        case G_TYPE_FLOAT:
+        case G_TYPE_DOUBLE:
+          arg->arg_type = G_TYPE_DOUBLE;
+          arg->d.double_data = va_arg (args, gdouble);
+          break;
+        case G_TYPE_STRING:
+          if (arg->arg_type != GTK_TYPE_IDENTIFIER)
+            arg->arg_type = G_TYPE_STRING;
+          arg->d.string_data = va_arg (args, gchar*);
+          if (!arg->d.string_data)
+            {
+              g_warning ("gtk_binding_entry_add_signal(): type `%s' arg[%u] is `NULL'",
+                         g_type_name (arg->arg_type),
+                         i);
+              i += n_args + 1;
+            }
+          break;
+        default:
+          g_warning ("gtk_binding_entry_add_signal(): unsupported type `%s' for arg[%u]",
+                     g_type_name (arg->arg_type), i);
+          i += n_args + 1;
+          break;
+        }
     }
   va_end (args);
 
@@ -973,10 +990,10 @@ gtk_binding_entry_add_signal (GtkBindingSet  *binding_set,
  * Deprecated: 3.0
  */
 void
-gtk_binding_set_add_path (GtkBindingSet             *binding_set,
-                         GtkPathType         path_type,
-                         const gchar        *path_pattern,
-                         GtkPathPriorityType priority)
+gtk_binding_set_add_path (GtkBindingSet      *binding_set,
+                          GtkPathType         path_type,
+                          const gchar        *path_pattern,
+                          GtkPathPriorityType priority)
 {
   PatternSpec *pspec;
   GSList **slist_p, *slist;
@@ -1024,18 +1041,18 @@ gtk_binding_set_add_path (GtkBindingSet      *binding_set,
       slist = slist->next;
       
       if (g_pattern_spec_equal (tmp_pspec->pspec, pspec->pspec))
-       {
-         GtkPathPriorityType lprio = tmp_pspec->seq_id >> 28;
-
-         pattern_spec_free (pspec);
-         pspec = NULL;
-         if (lprio < priority)
-           {
-             tmp_pspec->seq_id &= 0x0fffffff;
-             tmp_pspec->seq_id |= priority << 28;
-           }
-         break;
-       }
+        {
+          GtkPathPriorityType lprio = tmp_pspec->seq_id >> 28;
+
+          pattern_spec_free (pspec);
+          pspec = NULL;
+          if (lprio < priority)
+            {
+              tmp_pspec->seq_id &= 0x0fffffff;
+              tmp_pspec->seq_id |= priority << 28;
+            }
+          break;
+        }
     }
   if (pspec)
     {
@@ -1046,10 +1063,10 @@ gtk_binding_set_add_path (GtkBindingSet      *binding_set,
 
 static gboolean
 binding_match_activate (GSList          *pspec_list,
-                       GObject         *object,
-                       guint            path_length,
-                       gchar           *path,
-                       gchar           *path_reversed,
+                        GObject         *object,
+                        guint            path_length,
+                        gchar           *path,
+                        gchar           *path_reversed,
                         gboolean        *unbound)
 {
   GSList *slist;
@@ -1067,7 +1084,7 @@ binding_match_activate (GSList          *pspec_list,
       if (pspec->type != GTK_PATH_WIDGET_CLASS)
         {
           if (g_pattern_match (pspec->pspec, path_length, path, path_reversed))
-           binding_set = pspec->user_data;
+            binding_set = pspec->user_data;
         }
 
       if (binding_set)
@@ -1088,7 +1105,7 @@ binding_match_activate (GSList          *pspec_list,
 
 static gint
 gtk_binding_pattern_compare (gconstpointer new_pattern,
-                            gconstpointer existing_pattern)
+                             gconstpointer existing_pattern)
 {
   register const PatternSpec *np  = new_pattern;
   register const PatternSpec *ep  = existing_pattern;
@@ -1102,8 +1119,8 @@ gtk_binding_pattern_compare (gconstpointer new_pattern,
 
 static GSList*
 gtk_binding_entries_sort_patterns (GSList      *entries,
-                                  GtkPathType  path_id,
-                                  gboolean     is_release)
+                                   GtkPathType  path_id,
+                                   gboolean     is_release)
 {
   GSList *patterns;
   GSList *tmp_list;
@@ -1125,34 +1142,34 @@ gtk_binding_entries_sort_patterns (GSList      *entries,
       GSList *slist = NULL;
 
       if (is_release != ((entry->modifiers & GDK_RELEASE_MASK) != 0))
-       continue;
+        continue;
 
       binding_set = entry->binding_set;
 
       if (binding_set->current)
-       continue;
+        continue;
       binding_set->current = entry;
 
       switch (path_id)
-       {
-       case GTK_PATH_WIDGET:
-         slist = binding_set->widget_path_pspecs;
-         break;
-       case GTK_PATH_WIDGET_CLASS:
-         slist = binding_set->widget_class_pspecs;
-         break;
-       case GTK_PATH_CLASS:
-         slist = binding_set->class_branch_pspecs;
-         break;
-       }
+        {
+        case GTK_PATH_WIDGET:
+          slist = binding_set->widget_path_pspecs;
+          break;
+        case GTK_PATH_WIDGET_CLASS:
+          slist = binding_set->widget_class_pspecs;
+          break;
+        case GTK_PATH_CLASS:
+          slist = binding_set->class_branch_pspecs;
+          break;
+        }
 
       for (; slist; slist = slist->next)
-       {
-         PatternSpec *pspec;
+        {
+          PatternSpec *pspec;
 
-         pspec = slist->data;
-         patterns = g_slist_insert_sorted (patterns, pspec, gtk_binding_pattern_compare);
-       }
+          pspec = slist->data;
+          patterns = g_slist_insert_sorted (patterns, pspec, gtk_binding_pattern_compare);
+        }
     }
 
   return patterns;
@@ -1160,8 +1177,8 @@ gtk_binding_entries_sort_patterns (GSList      *entries,
 
 static gboolean
 gtk_bindings_activate_list (GObject   *object,
-                           GSList    *entries,
-                           gboolean   is_release)
+                            GSList    *entries,
+                            gboolean   is_release)
 {
   gboolean handled = FALSE;
 
@@ -1179,24 +1196,24 @@ gtk_bindings_activate_list (GObject   *object,
       patterns = gtk_binding_entries_sort_patterns (entries, GTK_PATH_CLASS, is_release);
       class_type = G_TYPE_FROM_INSTANCE (object);
       while (class_type && !handled)
-       {
-         guint path_length;
-         gchar *path;
-         gchar *path_reversed;
-
-         path = g_strdup (g_type_name (class_type));
-         path_reversed = g_strdup (path);
-         g_strreverse (path_reversed);
-         path_length = strlen (path);
-         handled = binding_match_activate (patterns, object, path_length, path, path_reversed, &unbound);
-         g_free (path);
-         g_free (path_reversed);
+        {
+          guint path_length;
+          gchar *path;
+          gchar *path_reversed;
+
+          path = g_strdup (g_type_name (class_type));
+          path_reversed = g_strdup (path);
+          g_strreverse (path_reversed);
+          path_length = strlen (path);
+          handled = binding_match_activate (patterns, object, path_length, path, path_reversed, &unbound);
+          g_free (path);
+          g_free (path_reversed);
 
           if (unbound)
             break;
 
-         class_type = g_type_parent (class_type);
-       }
+          class_type = g_type_parent (class_type);
+        }
       g_slist_free (patterns);
 
       if (unbound)
@@ -1219,8 +1236,8 @@ gtk_bindings_activate_list (GObject   *object,
  */
 gboolean
 gtk_bindings_activate (GObject         *object,
-                      guint            keyval,
-                      GdkModifierType  modifiers)
+                       guint            keyval,
+                       GdkModifierType  modifiers)
 {
   GSList *entries = NULL;
   GdkDisplay *display;
@@ -1274,13 +1291,13 @@ gtk_bindings_activate_event (GObject     *object,
   key_hash = binding_key_hash_for_keymap (gdk_keymap_get_for_display (display));
 
   entries = _gtk_key_hash_lookup (key_hash,
-                                 event->hardware_keycode,
-                                 event->state,
-                                 BINDING_MOD_MASK () & ~GDK_RELEASE_MASK,
-                                 event->group);
+                                  event->hardware_keycode,
+                                  event->state,
+                                  BINDING_MOD_MASK () & ~GDK_RELEASE_MASK,
+                                  event->group);
   
   handled = gtk_bindings_activate_list (object, entries,
-                                       event->type == GDK_KEY_RELEASE);
+                                        event->type == GDK_KEY_RELEASE);
 
   g_slist_free (entries);
 
index 40b93c1b049276bbfd960192f1d2d467657fb6ce..374d7df935178d4dbb89356cf413112f8818df2a 100644 (file)
@@ -55,6 +55,7 @@
 #include "gtkiconfactory.h"
 #include "gtkactivatable.h"
 #include "gtksizerequest.h"
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
 
index e1ad0f8b0dedbcc22631605ef9a6fb27ef45cc0d..cbd4b3573c9a245745a8177d6d75ceab47eeef5b 100644 (file)
@@ -28,6 +28,7 @@
 #include "gtkeventbox.h"
 #include "gtkmain.h"
 #include "gtksizerequest.h"
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 
 
index 4fdcfe5b0de4cae783905ce24ef6eeadaf215022..c1ca3bc7d94dfef9f3f4127a5b799fe595812129 100644 (file)
@@ -40,6 +40,7 @@
 #include "gtktreeselection.h"
 #include "gtkvseparator.h"
 #include "gtkwindow.h"
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 
 #include <gobject/gvaluecollector.h>
index 0ae08277f7c85e0810a3b7ef1513c7e4d3ac3f67..d5135209cd268fbc7cb95f999d1b2f4a6c62f70c 100644 (file)
 #include <string.h>
 #include <stdlib.h>
 
+#include <gobject/gobjectnotifyqueue.c>
+#include <gobject/gvaluecollector.h>
+
 #include "gtkbuildable.h"
 #include "gtkbuilderprivate.h"
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 #include "gtkmain.h"
 #include "gtkmarshalers.h"
@@ -42,8 +46,6 @@
 #include "gtkwindow.h"
 #include "gtkintl.h"
 #include "gtktoolbar.h"
-#include <gobject/gobjectnotifyqueue.c>
-#include <gobject/gvaluecollector.h>
 
 
 /**
index 67c28d8cfb8cf3c4f149e395588f5f06927d2356..0920037d2b5e6907aea65b835b26d219798e7842 100644 (file)
@@ -58,6 +58,7 @@
 #include "gtkwindow.h"
 #include "gtktreeview.h"
 #include "gtktreeselection.h"
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 #include "gtkentryprivate.h"
 #include "gtkcelllayout.h"
index c68bb5b266b77a6e91fd83052c664f35793c4360..670ca89f0a0e5ce1b1e98ca935e5926a8163f041 100644 (file)
@@ -52,6 +52,7 @@
 
 #include "gtkfilechooserbutton.h"
 
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 
 /* **************** *
index 5a8843f712a1d99e35751e8f7e5946d0c42b5b60..04950f6feaebb42af340ddcfb3db040a10c2f182 100644 (file)
@@ -29,6 +29,7 @@
 #include "gtkframe.h"
 #include "gtklabel.h"
 #include "gtkprivate.h"
+#include "gtktypebuiltins.h"
 #include "gtkintl.h"
 #include "gtkbuildable.h"
 
index c96f66579df64f1f8c0cd5f1c3df60be2a1ed52b..a57d81b992a1ad67334732de8695a093ec401855 100644 (file)
  */
 
 #include "config.h"
+
 #include <stdlib.h>
+
 #include "gtkhandlebox.h"
 #include "gtkinvisible.h"
 #include "gtkmain.h"
 #include "gtkmarshalers.h"
 #include "gtkwindow.h"
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
 
index 2c2f95e0fc09f6c762cabc21b5ba5cb20cd33644..46744499c86afdee819eb6155e1169cb2e4a1578 100644 (file)
  */
 
 #include "config.h"
+
 #include <stdlib.h>
 #include <errno.h>
 #include <string.h>
+
 #include "gtkiconfactory.h"
 #include "gtkiconcache.h"
 #include "gtkdebug.h"
@@ -38,7 +40,7 @@
 #include "gtkintl.h"
 #include "gtkbuildable.h"
 #include "gtkbuilderprivate.h"
-
+#include "gtktypebuiltins.h"
 
 static GSList *all_icon_factories = NULL;
 
index 69d0564ee24db458e17f268d7de5c3e947ffc61d..73b8b256556cf9f429a72424b7c54b94a9a3e7b3 100644 (file)
@@ -41,6 +41,7 @@
 #include "gtkscrollable.h"
 #include "gtksizerequest.h"
 #include "gtktreednd.h"
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 
 /**
index 340b71cb7a7992d9c7a1e6b3c64e374e4942a094..2d8e130f95fa7faa3e2dea7a777a4803ad23dbe3 100644 (file)
@@ -25,6 +25,7 @@
  */
 
 #include "config.h"
+
 #include <math.h>
 #include <string.h>
 
@@ -36,6 +37,7 @@
 #include "gtksizerequest.h"
 #include "gtkintl.h"
 #include "gtkprivate.h"
+#include "gtktypebuiltins.h"
 
 /**
  * SECTION:gtkimage
index 9905e9830d442bef9de31440c96a996fe40aab87..e82095e01cf937c6be2dfa338d414dc34871ca51 100644 (file)
@@ -46,6 +46,7 @@
 #include "gtkintl.h"
 #include "gtkprivate.h"
 #include "gtkstock.h"
+#include "gtktypebuiltins.h"
 
 /**
  * SECTION:gtkinfobar
index 1d664632e2f47ab5d8a858b46090a64f621960a1..1ae459627c09eb36c8787b23a01799b326088da3 100644 (file)
@@ -50,6 +50,7 @@
 #include "gtkshow.h"
 #include "gtktooltip.h"
 #include "gtkprivate.h"
+#include "gtktypebuiltins.h"
 
 /*rint() is only available in GCC and/or C99*/
 #if (__STDC_VERSION__ < 199901L && !defined __GNUC__)
index 82a7392e543c239718ba0cb39027616d51a7614c..6fe41c4df81a0eeb130ae6dbc6efd26142111a5c 100644 (file)
@@ -33,7 +33,6 @@
 
 
 #include <gdk/gdk.h>
-#include <gtk/gtktypeutils.h>
 #include <gtk/gtkwidget.h>
 #ifdef G_PLATFORM_WIN32
 #include <gtk/gtkbox.h>
index 200b7fd465efd1835be48a80b07811916216cb0f..adb6646134f705dacd66f4f619a6a2bead8af43d 100644 (file)
@@ -46,6 +46,7 @@
 #include "gtksettings.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
+#include "gtktypebuiltins.h"
 
 #define NAVIGATION_REGION_OVERSHOOT 50  /* How much the navigation region
                                          * extends below the submenu
index 66669fa9e9c49a0db24c1a8e5a12d42b3bb2e733..42f2f25819a8b190f568be547ed29b04f56f1227 100644 (file)
@@ -37,9 +37,9 @@
 #include "gtksettings.h"
 #include "gtksizerequest.h"
 #include "gtkwindow.h"
-
 #include "gtkintl.h"
 #include "gtkprivate.h"
+#include "gtktypebuiltins.h"
 
 #define BORDER_SPACING  0
 #define DEFAULT_IPADDING 1
index ec60a8502899057e5f1d020f2de1abbf92c4e674..6cfc53e8df1437f36d9b942956d349fe5bd70850 100644 (file)
@@ -25,6 +25,7 @@
  */
 
 #include "config.h"
+
 #include <string.h>
 
 #include "gtkaccellabel.h"
@@ -40,6 +41,7 @@
 #include "gtkbuildable.h"
 #include "gtkactivatable.h"
 #include "gtkintl.h"
+#include "gtktypebuiltins.h"
 
 
 enum {
index 1dfecc2a7b51b591c5f2644a118ac3ee41860c61..92b58e75e8deec6b0f1cb0d609f2202f50322346 100644 (file)
@@ -40,6 +40,7 @@
 #include "gtkwindow.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
+#include "gtktypebuiltins.h"
 
 #define MENU_SHELL_TIMEOUT   500
 
index 38d39a1da2b0fa59a25c4d25dbd8b305f244782a..dfa31314967d3cd1e6656695edc1515324b4780f 100644 (file)
@@ -26,6 +26,7 @@
  */
 
 #include "config.h"
+
 #include <string.h>
 
 #include "gtkmessagedialog.h"
@@ -39,6 +40,7 @@
 #include "gtkiconfactory.h"
 #include "gtkintl.h"
 #include "gtkprivate.h"
+#include "gtktypebuiltins.h"
 
 /**
  * SECTION:gtkmessagedialog
index 6034851e7c867591c6f107c38e863095ac9c769a..0d9d9fad4674619c8c9371d2d3a60e602a7dc3a7 100644 (file)
@@ -42,6 +42,7 @@
 #include "gtkprivate.h"
 #include "gtkdnd.h"
 #include "gtkbuildable.h"
+#include "gtktypebuiltins.h"
 
 
 /**
index e3cfc98bab9c8ccb679aca5d6cfbef5524d05f96..1a7e51e359c47e5ab76eb38d74d612553120e583 100644 (file)
@@ -33,7 +33,7 @@
 #include "gtkmarshalers.h"
 #include "gtkorientable.h"
 #include "gtkwindow.h"
-
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
 
index a8101746d1c05991f81a94bfb47be7202c3b368c..139041a329de475f224f8990feba52a05cb2e0af 100644 (file)
 #include "config.h"
 
 #include <errno.h>
-#include <stdlib.h>       
+#include <stdlib.h>
 #include <math.h>
-
 #include <string.h>
+
+#include <cairo-pdf.h>
+
 #include "gtkprintoperation-private.h"
 #include "gtkmarshalers.h"
-#include <cairo-pdf.h>
 #include "gtkintl.h"
 #include "gtkprivate.h"
 #include "gtkmessagedialog.h"
+#include "gtktypebuiltins.h"
 
 #define SHOW_PROGRESS_TIME 1200
 
index 2235864869e2bff561454e49a249356311ad625a..7507bd71e9bfb69b0d41bac5fa93a9c7ca1fd568 100644 (file)
  */
 
 #include "config.h"
+
 #include <string.h>
 #include <stdlib.h>
+
 #include <glib/gprintf.h>
-#include <gtk/gtk.h>
+
 #include "gtkprintsettings.h"
 #include "gtkprintutils.h"
+#include "gtktypebuiltins.h"
+#include "gtkwidget.h"
 
 
 typedef struct _GtkPrintSettingsClass GtkPrintSettingsClass;
index 7cb734c276b5a5de0e49c4fe0cfc5e4a9c9a93a2..2d61cdac31f45cdb8c02c7cd5de422da2ad5966f 100644 (file)
  */
 
 #include "config.h"
+
 #include <stdlib.h>
 #include <string.h>
 #include <ctype.h>
 #include <stdio.h>
 #include <math.h>
 
-#include "gtkintl.h"
-#include "gtkprivate.h"
+#include "gtkprintunixdialog.h"
+
+#include "gtkcustompaperunixdialog.h"
+#include "gtkprintbackend.h"
+#include "gtkprinter-private.h"
+#include "gtkprinteroptionwidget.h"
+#include "gtkprintutils.h"
 
 #include "gtkspinbutton.h"
 #include "gtkcellrendererpixbuf.h"
 #include "gtklabel.h"
 #include "gtkeventbox.h"
 #include "gtkbuildable.h"
-
-#include "gtkcustompaperunixdialog.h"
-#include "gtkprintbackend.h"
-#include "gtkprinter-private.h"
-#include "gtkprintunixdialog.h"
-#include "gtkprinteroptionwidget.h"
-#include "gtkprintutils.h"
-
 #include "gtkmessagedialog.h"
 #include "gtkbutton.h"
+#include "gtkintl.h"
+#include "gtkprivate.h"
+#include "gtktypebuiltins.h"
 
 #define EXAMPLE_PAGE_AREA_SIZE 110
 #define RULER_DISTANCE 7.5
index 7a7bebf2e47e4bcc4b290408d20fc61fa4e9539e..3d3e8563ec4780811059ce8458fb46ccc3f2a1b5 100644 (file)
@@ -39,6 +39,7 @@
 #include "gtkwindow.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
+#include "gtktypebuiltins.h"
 
 /**
  * SECTION:gtkrange
index 689425f0fdadf4710a2255d7d2620c51b8edbd6a..78d01ac362dd5d04fc5d08df37cc2593eff0f3bd 100644 (file)
@@ -53,7 +53,7 @@
 #include "gtkstock.h"
 #include "gtkvbox.h"
 #include "gtkwindow.h"
-
+#include "gtktypebuiltins.h"
 #include "gtkintl.h"
 
 /**
index 81726cde66abc20d111a4062bf7ec17c0c397be2..828dd8a74a45245c96016fd348375d9b88a0f483 100644 (file)
@@ -34,6 +34,7 @@
 #include "gtkscrolledwindow.h"
 #include "gtkwindow.h"
 #include "gtkprivate.h"
+#include "gtktypebuiltins.h"
 #include "gtkintl.h"
 
 
index c3f87d5296b063e774cc71ed56b7514fca4d20e3..5148f0e108153869c27ef6b6bb4a9c1cf87ed04b 100644 (file)
@@ -43,6 +43,7 @@
 #include "gtksettings.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
+#include "gtktypebuiltins.h"
 
 #define MIN_SPIN_BUTTON_WIDTH 30
 #define MAX_TIMER_CALLS       5
index e38b448e2533a20d2fafdc9ab231f1e22d836a98..334c9a487336a241920e543cb377ce583ddc973f 100644 (file)
@@ -26,6 +26,7 @@
  */
 
 #include "config.h"
+
 #include "gtkframe.h"
 #include "gtklabel.h"
 #include "gtkmarshalers.h"
@@ -34,6 +35,7 @@
 #include "gtkprivate.h"
 #include "gtkintl.h"
 #include "gtkbuildable.h"
+#include "gtktypebuiltins.h"
 
 /**
  * SECTION:gtkstatusbar
index 27f85d925730eb0950fab106c35979d876d363dd..6e0751edb5363d6cfe49b9748bb3a851756dadff 100644 (file)
 #include "gtkprivate.h"
 #include "gtkwidget.h"
 #include "gtktooltip.h"
+#include "gtkicontheme.h"
+#include "gtklabel.h"
+#include "gtktypebuiltins.h"
 
 #ifdef GDK_WINDOWING_X11
 #include "gdk/x11/gdkx.h"
 #endif
-#ifdef GDK_WINDOWING_WIN32
-#include "gdk/win32/gdkwin32.h"
-#endif
 
 #ifdef GDK_WINDOWING_WIN32
-#include "gtkicontheme.h"
-#include "gtklabel.h"
-
-#include "win32/gdkwin32.h"
+#include "gdk/win32/gdkwin32.h"
 #define WM_GTK_TRAY_NOTIFICATION (WM_USER+1)
 #endif
 
-#ifdef GDK_WINDOWING_QUARTZ
-#include "gtkicontheme.h"
-#include "gtklabel.h"
-#endif
-
 #define BLINK_TIMEOUT 500
 
 enum
index 57e4b8f227693af679bd0305a9fef89148d2f464..b32d4b162fd9a93b26bf73fc24f999652dcb7ae7 100644 (file)
 
 
 #include <gdk/gdk.h>
-#include <gtk/gtktypeutils.h> /* for GtkTranslateFunc */
 
 G_BEGIN_DECLS
 
+/*
+ * GtkTranslateFunc:
+ * @path: The id of the message. In #GtkActionGroup this will be a label
+ *   or tooltip from a #GtkActionEntry.
+ * @func_data: user data passed in when registering the function
+ *
+ * The function used to translate messages in e.g. #GtkIconFactory
+ * and #GtkActionGroup.
+ *
+ * Returns: the translated message
+ */
+typedef gchar * (*GtkTranslateFunc) (const gchar  *path,
+                                     gpointer      func_data);
+
 typedef struct _GtkStockItem GtkStockItem;
 
 struct _GtkStockItem
index cb62ebfa5c67a3143a4fe6bf204feaf11268f645..b54cad7472bead3813bc3154c0267f364aa33086 100644 (file)
  */
 
 #include "config.h"
+
+#include <stdlib.h>
+#include <string.h>
+
 #include "gtkmain.h"
 #include "gtktexttag.h"
 #include "gtktexttypes.h"
@@ -55,9 +59,7 @@
 #include "gtkintl.h"
 #include "gtkmarshalers.h"
 #include "gtkprivate.h"
-
-#include <stdlib.h>
-#include <string.h>
+#include "gtktypebuiltins.h"
 
 enum {
   EVENT,
index 1b07b59108a7d9d1773159733f7af44d635bf10b..b57db0f1e773c74b0358bae64fd247deafd75a96 100644 (file)
@@ -50,6 +50,7 @@
 #include "gtkwidgetprivate.h"
 #include "gtkwindow.h"
 #include "gtkscrollable.h"
+#include "gtktypebuiltins.h"
 
 
 /**
index c2161a7b0412312a5e4354b1406af6e001b205cd..23ebab621c162bd21dba46c5e616c7b41eba137e 100644 (file)
@@ -55,6 +55,7 @@
 #include "gtkvbox.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
+#include "gtktypebuiltins.h"
 
 
 /**
index abcc64014b57405de484f1134afbc316413d88bd..20cc10b7970ead19cb3ca37294eb723e12db6691 100644 (file)
 
 #include "config.h"
 
-#include "gtktoolpaletteprivate.h"
-
-#include <gtk/gtk.h>
 #include <math.h>
 #include <string.h>
+
+#include "gtktoolpaletteprivate.h"
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
 
index 5429039990f7ddfbc906e6150c4c13b2688758bd..195a43adfb61dcd37ba0e0a40c34e0bff67fd645 100644 (file)
@@ -26,7 +26,7 @@
 
 #include "gtktoolpaletteprivate.h"
 #include "gtkmarshalers.h"
-
+#include "gtktypebuiltins.h"
 #include "gtkprivate.h"
 #include "gtkscrollable.h"
 #include "gtkintl.h"
index 2bdd421f9455e89ce990b91e5920039ef12b65ef..a8f6a1191372b069ecdf1117ba4732d44fbc18f4 100644 (file)
  */
 
 #include "config.h"
+
 #include <math.h>
 #include <string.h>
 
+#include "x11/gdkx.h"
+#include <X11/Xatom.h>
+#include <cairo-xlib.h>
+
 #include "gtkintl.h"
 #include "gtkprivate.h"
 #include "gtktrayicon.h"
 #include "gtktestutils.h"
 #include "gtkdebug.h"
-
-#include "x11/gdkx.h"
-#include <X11/Xatom.h>
-#include <cairo-xlib.h>
+#include "gtktypebuiltins.h"
 
 #define SYSTEM_TRAY_REQUEST_DOCK    0
 #define SYSTEM_TRAY_BEGIN_MESSAGE   1
index d8613066c35e5280160e66185363756c935b0e2c..0032ae51e636a16c5e5183abe5416ab98867ccb3 100644 (file)
@@ -49,6 +49,7 @@
 #include "gtkprivate.h"
 #include "gtkwidgetprivate.h"
 #include "gtkentryprivate.h"
+#include "gtktypebuiltins.h"
 
 
 /**
index 43f592183f36279c03cc91f91df0f3345c7d5834..00a2ea7499ee66ec9ce0005c6d29d3b3e8afdc4e 100644 (file)
@@ -36,6 +36,7 @@
 #include "gtkcellareabox.h"
 #include "gtkprivate.h"
 #include "gtkintl.h"
+#include "gtktypebuiltins.h"
 
 
 /**
diff --git a/gtk/gtktypeutils.c b/gtk/gtktypeutils.c
deleted file mode 100644 (file)
index d1e74d9..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/* GTK - The GIMP Toolkit
- * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.         See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-/*
- * Modified by the GTK+ Team and others 1997-2000.  See the AUTHORS
- * file for a list of people on the GTK+ Team.  See the ChangeLog
- * files for a list of changes.  These files are distributed with
- * GTK+ at ftp://ftp.gtk.org/pub/gtk/. 
- */
-
-#include "config.h"
-#include <string.h> /* strcmp */
-
-#include "gtktypeutils.h"
-#include "gtkintl.h"
-
-
-
-GType
-gtk_identifier_get_type (void)
-{
-  static GType our_type = 0;
-  
-  if (our_type == 0)
-    {
-      GTypeInfo tinfo = { 0, };
-      our_type = g_type_register_static (G_TYPE_STRING, I_("GtkIdentifier"), &tinfo, 0);
-    }
-
-  return our_type;
-}
diff --git a/gtk/gtktypeutils.h b/gtk/gtktypeutils.h
deleted file mode 100644 (file)
index 91ef217..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-/* GTK - The GIMP Toolkit
- * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.         See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-/*
- * Modified by the GTK+ Team and others 1997-2000.  See the AUTHORS
- * file for a list of people on the GTK+ Team.  See the ChangeLog
- * files for a list of changes.  These files are distributed with
- * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
- */
-
-#if !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
-#error "Only <gtk/gtk.h> can be included directly."
-#endif
-
-#ifndef __GTK_TYPE_UTILS_H__
-#define __GTK_TYPE_UTILS_H__
-
-/* enum types generated by glib-mkenums
- */
-#include <gtk/gtktypebuiltins.h>
-
-G_BEGIN_DECLS
-
-/* urg */
-#define GTK_TYPE_IDENTIFIER (gtk_identifier_get_type ())
-GType gtk_identifier_get_type (void) G_GNUC_CONST;
-
-typedef gchar * (*GtkTranslateFunc) (const gchar  *path,
-                                     gpointer      func_data);
-
-
-G_END_DECLS
-
-#endif /* __GTK_TYPE_UTILS_H__ */
index 4836a356867afb1b266e7493fe8c6deea278e111..66811ffb6a18fa7fb77d4c462fd0eebbc580e67f 100644 (file)
@@ -63,6 +63,7 @@
 #include "gtkmodifierstyle.h"
 #include "gtkversion.h"
 #include "gtkdebug.h"
+#include "gtktypebuiltins.h"
 
 
 /**
index f514206931eb0234e58e7e98b92c43f780c4d634..19501f2a9df440c117a2793a1ab62439d33b7829 100644 (file)
@@ -26,7 +26,7 @@
 
 #include "config.h"
 
-#include "gtkintl.h"
+#include "gtkwindow.h"
 
 #include <string.h>
 #include <stdlib.h>
@@ -35,7 +35,6 @@
 
 #include "gtkprivate.h"
 #include "gtkrc.h"
-#include "gtkwindow.h"
 #include "gtkwindowprivate.h"
 #include "gtkaccelgroupprivate.h"
 #include "gtkbindings.h"
@@ -49,6 +48,8 @@
 #include "gtkplug.h"
 #include "gtkbuildable.h"
 #include "gtkwidgetprivate.h"
+#include "gtkintl.h"
+#include "gtktypebuiltins.h"
 
 #ifdef GDK_WINDOWING_X11
 #include "x11/gdkx.h"
index da8ed2bd9bca2974b5fe5adc311d475645d9094e..5af45482a0b52e06f02065c0f728278d8fa688d4 100644 (file)
@@ -197,7 +197,6 @@ gtk/gtktreesortable.c
 gtk/gtktreestore.c
 gtk/gtktreeview.c
 gtk/gtktreeviewcolumn.c
-gtk/gtktypeutils.c
 gtk/gtkuimanager.c
 gtk/gtkvbbox.c
 gtk/gtkvbox.c
index 3bb4266da79c72f675999137b84a1327916166af..55dee16a084d6a0477a3e0311574ccc0d8c2684a 100644 (file)
@@ -198,7 +198,6 @@ gtk/gtktreesortable.c
 gtk/gtktreestore.c
 gtk/gtktreeview.c
 gtk/gtktreeviewcolumn.c
-gtk/gtktypeutils.c
 gtk/gtkuimanager.c
 gtk/gtkvbbox.c
 gtk/gtkvbox.c